<?php

namespace app\common\validate\subject;

use think\Validate;

class Like extends Validate
{
    	protected $rule = [
            'id' => ['require', 'number'],
            'busid' => ['require', 'number'],
            'subid' => ['require', 'number'],
            'like' => ['number'],
            'buy' => ['number'],
            'cid' => ['number']
        ];

        protected $message = [
            'id' => "id",
            'busid' => "用户id",
            'subid' => "课程id",
            'like' => "点赞数",
            'buy' => "没有购买了该课程",
            'cid' => "优惠卷错误"
        ];

        /**
         * 验证场景定义
         * 格式：'场景名称'	=>	['字段1','字段2'...]
         *
         * @var array
         */
        protected $scene = [
            'profile' => ['subid','busid','cid']
        ];
}
